package ru.rchervot.sanasar.client.view;

import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.VerticalPanel;

public class SelectedSeveralView extends Composite 
implements SelectedSeveralPresenter.Display {

	private VerticalPanel basePanel = new VerticalPanel();
	private final Label selectedSeveralLabel = new Label();
	private Presenter presenter;
	
	SelectedSeveralView() {
		
		basePanel.setSize("100%", "100%");
		basePanel.add(selectedSeveralLabel);
		this.initWidget(basePanel);
	}
	
	@Override
	public void setPresenter(Presenter presenter) {
		this.presenter = presenter;
	}

	@Override
	public void render(int numberOfSelectedItems) {
		selectedSeveralLabel.setText(numberOfSelectedItems + " Items selected");
		
	}
}
